package main

//https://eddycjy.com/posts/go/gin/2018-02-13-api-03/#%E6%B6%89%E5%8F%8A%E7%9F%A5%E8%AF%86%E7%82%B9

import (
	"GOGINEXAMPLE/pkg/setting"
	"GOGINEXAMPLE/routers"
	"fmt"
	"net/http"
)

func main() {

	s := &http.Server{
		Addr: fmt.Sprintf(":%d", setting.HTTPPort),

		Handler:        routers.InitRouter(),
		ReadTimeout:    setting.ReadTimeout,
		WriteTimeout:   setting.WriteTimeout,
		MaxHeaderBytes: 1 << 20,
	}

	s.ListenAndServe()
}
